<template>
  <div class="basic_info">
    <div class="info_operation_btn">
      <div class="btn_left">
        <el-button @click="onLookBill">查看单据</el-button>
        <el-button :disabled="!buttonsPermissions.DaYin" :class="!buttonsPermissions.DaYin ? 'disabled_button' : ''"
          @click="handleShortcutKeyPrint">打印(P)</el-button>
      </div>
      <div class="btn_right">
        <i @click="onShowColumn()" class="set_up el-icon-s-tools"></i>
      </div>
    </div>
    <div class="info_content_div">
      <div class="div_table">
        <div class="div_screen">
          <div class="screen_left">
            <el-select @change="changeDate" v-model="monthValue">
              <el-option v-for="item in monthOptions" :key="item.value" :label="item.label"
                :value="item.value"></el-option>
            </el-select>
            <el-date-picker v-if="isShowDate" v-model="nowDate" type="daterange" range-separator="~"
              start-placeholder="开始日期" end-placeholder="结束日期" @change="onClickPicker"
              value-format="yyyy-MM-dd"></el-date-picker>
            <el-button type="primary" @click="onQuery">查询</el-button>
            <p>商品名称：{{ paramsData.goodsName }}</p>
          </div>
          <div class="screen_right">
            <el-checkbox v-model="queryData.isShowHcdj">显示红冲单据</el-checkbox>
          </div>
        </div>
        <div class="table_content">
          <el-table show-summary ref="table" :summary-method="getSummaries" highlight-current-row :header-cell-style="{
            color: '#666666',
            textAlign: 'center',
            height: '30px',
            borderColor: '#dddddd',
          }" :cell-style="{ textAlign: 'center' }" :data="tableData" height="100%" style="width: 100%"
            @row-dblclick="handleBill" @current-change="handleCurrentRow">
            <el-table-column :resizable="false" label="序号" type="index" width="50"></el-table-column>
            <template v-for="(item, index) in columnData">
              <el-table-column :show-overflow-tooltip="true" :key="index"
                :label="item.zidingyiName ? item.zidingyiName : item.morenName" v-if="item.zidingyiState"
                :prop="item.props" min-width="120px" :sortable="item.sortable" :width="item.props=='goodsName'?'300px':item.cellWidth">
                <template slot-scope="scope">
                <span v-if="item.props == 'goodsName'" style="width: 100%;  white-space: normal;
  word-wrap: break-word;
  overflow: hidden;
  text-overflow: ellipsis;
  display: -webkit-box;
  -webkit-line-clamp: 2;
  -webkit-box-orient: vertical;">{{scope.row[item.props]}}</span>
                <span v-else>{{scope.row[item.props]}}</span>
              </template>
              </el-table-column>
            </template>
          </el-table>
        </div>
        <div class="table_pagination">
          <div class="pagination_div">
            <el-pagination background @size-change="handleSizeChange" @current-change="handleCurrentChange"
              :current-page="queryData.pageNo" :page-sizes="[20, 50, 100, 200]" :page-size="queryData.pageSize"
              layout="jumper, prev, pager,next, sizes" :total="total"></el-pagination>
          </div>
        </div>
      </div>
    </div>
    <!-- 列配置弹框 -->
    <CConfiguration ref="setColumnRef" :columnDataArr="columnData" :defaultColumnDataArr="defaultColumnData"
      orderType="库存变动明细" @onSaveColumn="onSaveColumn"></CConfiguration>
    <!-- 打印 -->
    <dialog-print ref="print"></dialog-print>
    <!-- 新增树形结构数据弹框 -->
  </div>
</template>

<script>
import { mapGetters } from 'vuex'
import CConfiguration from '@/components/c_column/columnConfiguration1'
/**打印 */
import dialogPrint from '@/views/components/dialogPrintRecord'
import { getAction, postAction, downPostFile } from '@/api/manage'
import { dateStrFromDate } from '@/utils/DateFormatter'
import { JeecgListMixin } from '@/mixins/JeecgListMixin'
// 导入调用处理权限数据方法
import { handlePermissions, handleOtherPerms, formatMoney, formatPrice, formatNumber, delcommafy } from '@/utils/index'
export default {
  name: 'overflowOrderDetails',
  components: {
    CConfiguration,
    dialogPrint,
  },
  computed: {
    ...mapGetters(['name']),
    buttonsPermissions() {
      return handlePermissions('报溢单明细')
    },
    printPermissions() {
      return handleOtherPerms('单据可多次打印')
    },
  },
  mixins: [JeecgListMixin],
  created() {
    const data = this.$route.params.data
    if (data) {
      this.paramsData = data
      this.monthValue = this.paramsData.monthValue
      this.queryData.startDate = this.paramsData.startDate
      this.queryData.finishDate = this.paramsData.finishDate
      this.nowDate = [this.paramsData.startDate, this.paramsData.finishDate]
    }
    this.onRefresh()
    // 初始化列配置数据
    this.defaultColumnData = this.columnData
    this.selectTitle()
  },
  watch: {
    // 路由变化时，更新数据
    $route: {
      immediate: true,
      handler(val) {
        if (val.name === 'stockManage-stockRecord-overflowOrderDetails') {
          const data = val.params.data
          if (data && data != this.paramsData) {
            this.paramsData = data
            this.monthValue = this.paramsData.monthValue
            this.queryData.startDate = this.paramsData.startDate
            this.queryData.finishDate = this.paramsData.finishDate
            this.nowDate = [this.paramsData.startDate, this.paramsData.finishDate]
            this.onRefresh()
          }
        }
      }
    },
    'queryData.isShowHcdj': {
      deep: true,
      handler(val) {
        this.queryData.showFlag = val ? "1" : "0"
      },
    },
  },
  data() {
    return {
      // 查询条件数据
      queryData: {
        billOrderType: '11',// 单据类型10：报损单11：报溢单3：库存调整
        keywords: '', //搜索框值
        pageNo: 1, //默认开始页面
        pageSize: 20, //每页的数据条数
        startDate: '',// 开始时间
        finishDate: '',// 结束时间
        // 直接触发
        isShowHcdj: false,
        showFlag: '0', // 是否展示红冲单据 0-否 1-是
      },
      paramsData: {
        goodsId: '',
        goodsName: '',// 商品名称
        goodsTypeId: '',// 商品类别
        startDate: '',// 开始时间
        finishDate: '',// 结束时间
        storehouseId: '',
        sysUserId: '',
      },
      monthValue: '本月',
      monthOptions: [
        {
          value: '今日',
          label: '今日',
        },
        {
          value: '本周',
          label: '本周',
        },
        {
          value: '本月',
          label: '本月',
        },
        {
          value: '本年',
          label: '本年',
        },
      ],
      isShowDate: true, // 是否显示选择时间组件
      nowDate: [],
      // 表格数据
      tableData: [],
      isShowDate: true, // 是否显示选择时间组件
      columnData: [
        {
          morenName: '审核日期',
          zidingyiName: '',
          morenState: true,
          zidingyiState: true,
          noModify: false,
          sortable: true,
          cellWidth: '130px',
          props: 'checkTime',
        },
        {
          morenName: '单据日期',
          zidingyiName: '',
          morenState: true,
          zidingyiState: true,
          noModify: false,
          sortable: true,
          cellWidth: '130px',
          props: 'commitTime',
        },
        {
          morenName: '单据类型',
          zidingyiName: '',
          morenState: true,
          zidingyiState: true,
          noModify: false,
          cellWidth: '100px',
          props: 'billTypeText',
        },
        {
          morenName: '单据编号',
          zidingyiName: '',
          morenState: true,
          zidingyiState: true,
          noModify: false,
          cellWidth: '130px',
          props: 'orderNumber',
        },
        {
          morenName: '仓库',
          zidingyiName: '',
          morenState: true,
          zidingyiState: true,
          noModify: false,
          cellWidth: '130px',
          props: 'xghStorehouseName',
        },
        {
          morenName: '商品编码',
          zidingyiName: '',
          morenState: true,
          zidingyiState: true,
          noModify: false,
          cellWidth: '130px',
          props: 'goodsNumber',
        },
        {
          morenName: '商品名称',
          zidingyiName: '',
          morenState: true,
          zidingyiState: true,
          noModify: false,
          cellWidth: '130px',
          props: 'goodsName',
        },
        {
          morenName: '规格',
          zidingyiName: '',
          morenState: true,
          zidingyiState: true,
          noModify: false,
          cellWidth: '130px',
          props: 'norms',
        },
        {
          morenName: '单位',
          zidingyiName: '',
          morenState: true,
          zidingyiState: true,
          noModify: false,
          cellWidth: '100px',
          props: 'unit',
        },
        {
          morenName: '报溢数量',
          zidingyiName: '',
          morenState: true,
          zidingyiState: true,
          noModify: false,
          sortable: true,
          cellWidth: '100px',
          props: 'number',
        },
        {
          morenName: '单价',
          zidingyiName: '',
          morenState: true,
          zidingyiState: true,
          noModify: false,
          sortable: true,
          cellWidth: '100px',
          props: 'costPrice',
        },
        {
          morenName: '金额小计',
          zidingyiName: '',
          morenState: true,
          zidingyiState: true,
          noModify: false,
          sortable: true,
          cellWidth: '130px',
          props: 'price',
        },
        {
          morenName: '基本单位',
          zidingyiName: '',
          morenState: true,
          zidingyiState: true,
          noModify: false,
          cellWidth: '100px',
          props: 'basicUnit_dictText',
        },
        {
          morenName: '折算数量',
          zidingyiName: '',
          morenState: true,
          zidingyiState: true,
          noModify: false,
          cellWidth: '100px',
          props: 'zsNumber',
        },
        {
          morenName: '单据状态',
          zidingyiName: '',
          morenState: true,
          zidingyiState: true,
          noModify: false,
          cellWidth: '100px',
          props: 'billStatusText',
        },
        {
          morenName: '经手人',
          zidingyiName: '',
          morenState: true,
          zidingyiState: true,
          noModify: false,
          cellWidth: '130px',
          props: 'sysUserName',
        },
        {
          morenName: '制单人',
          zidingyiName: '',
          morenState: true,
          zidingyiState: true,
          noModify: false,
          cellWidth: '130px',
          props: 'createName',
        },
        {
          morenName: '制单日期',
          zidingyiName: '',
          morenState: true,
          zidingyiState: true,
          noModify: false,
          cellWidth: '130px',
          props: 'createTime',
        },
        {
          morenName: '备注',
          zidingyiName: '',
          morenState: true,
          zidingyiState: true,
          noModify: false,
          cellWidth: '130px',
          props: 'remark',
        },

      ],
      defaultColumnData: [],// 默认列配置
      columnKey: '报溢单明细',// 列配置的标识key
      updateId: '', // 修改列配置时返回的id
      total: 0,
      currentRow: '', // 选中的表格数据
      url: {
        exportXlsUrl: '/xghCheckOrder/xghCheckOrder/exportXls'
      },// 导出地址
      billName: '报溢单明细',
    }
  },
  updated() {
    this.$nextTick(() => {
      this.$refs.table.doLayout()
    })
  },
  mounted() {
  },
  methods: {
    // 打印
    async handleShortcutKeyPrint() {
      let obj = {
        ...this.paramsData,
        ...this.queryData,
        pageNo: 1,
        pageSize: 1000000,
      }
      let printExclusive = []
      const res = await getAction('/xghProfitLossOrder/xghProfitLossOrder/queryDetails', obj)
      if (res.code === 200) {
        let dataArr = res.result.records || []
        dataArr.forEach(item => {
          item.billId = item.profitLossOrder.id
          let profitLossOrder = Object.assign({}, item.profitLossOrder)
          delete item.profitLossOrder
          let newItem = Object.assign(profitLossOrder, item)
          // 转换金额
          newItem.billTypeText = '报溢单'
          //0.待审核 5.审核通过 10.作废 15.反审 20.红冲 25.终止 30.完成
          if (newItem.billOrderStatus == '0') {
            newItem.billStatusText = "待审核"
          } else if (newItem.billOrderStatus == '5') {
            newItem.billStatusText = "已审核"
          } else if (newItem.billOrderStatus == '10') {
            newItem.billStatusText = "已作废"
          } else if (newItem.billOrderStatus == '15') {
            newItem.billStatusText = "已反审"
          } else if (newItem.billOrderStatus == '20') {
            newItem.billStatusText = "已红冲"
          }
          printExclusive.push(newItem)
        })
      }
      this.onQuery()
      this.handlePrint(printExclusive)
    },
    handlePrint(printExclusive) {
      if (!this.buttonsPermissions.DaYin) {
        this.$elMessage.warning('未拥有打印权限！')
      } else if (!printExclusive || printExclusive.length <= 0) {
        this.$elMessage.warning('没有要打印的记录！')
      } else {
        let printData = {
          riqi: this.queryData.startDate.split(' ')[0] + '~' + this.queryData.finishDate.split(' ')[0],
          printExclusive,
        }
        // 可以多次打印设置
        if (this.printPermissions) {
          this.$refs.print.show(printData, this.columnData, this.billName)
        } else {
          if (this.$lcStorage.get('printLimitValue')) {
            // 获取打印次数
            this.getPrintNum(this.billName, (() => {
              this.$refs.print.show(printData, this.columnData, this.billName)
            }))
          } else {
            this.$refs.print.show(printData, this.columnData, this.billName)
          }
        }
      }
    },
    // 查询保存的列配置
    async selectTitle() {
      let obj = await this.$setColumn.selectColumn(this.columnKey)
      if (obj.code === 200) {
        this.updateId = obj.updateId
        this.columnData = obj.columnData
      } else if (obj.code === 500) {
        let id = await this.$setColumn.addColumn(this.columnKey, this.defaultColumnData, 'props')
        this.updateId = id
        this.columnData = this.defaultColumnData
      } else if (obj.code === 404) {
        this.columnData = this.defaultColumnData
      }
    },
    // 修改列配置后保存修改后的值
    async onSaveColumn(value) {
      this.columnData = value
      let res = await this.$setColumn.editColumn(this.columnKey, this.columnData, this.updateId)
      if (res.code == 200) {
        this.$elMessage.success(res.message)
      } else {
        this.$elMessage.error(res.message)
      }
    },
    // 导出
    exportExcel() {
      const fileName = '报溢单明细'
      let params = {
        ...this.queryData,
        fileName
      }
      this.handleExportXlsByStaff(fileName, params)
    },
    // 刷新
    onRefresh() {
      Object.assign(this.$data.queryData, this.$options.data().queryData)
      this.monthValue = this.paramsData.monthValue
      this.queryData.startDate = this.paramsData.startDate
      this.queryData.finishDate = this.paramsData.finishDate
      this.nowDate = [this.paramsData.startDate, this.paramsData.finishDate]
      let obj = {
        ...this.paramsData,
        ...this.queryData,
      }
      this.requestQuery(obj)
    },
    // 查询
    onQuery() {
      this.queryData.pageNo = 1
      this.getData()
    },
    // 获取数据
    getData() {
      let obj = {
        ...this.paramsData,
        ...this.queryData,
      }
      this.requestQuery(obj)
    },
    // 请求筛选条件数据
    requestQuery(obj) {
      getAction('/xghProfitLossOrder/xghProfitLossOrder/queryDetails', obj).then((res) => {
        if (res.code === 200) {
          this.tableData = []
          let dataArr = res.result.records || []
          dataArr.forEach(item => {
            item.billId = item.profitLossOrder.id
            let profitLossOrder = Object.assign({}, item.profitLossOrder)
            delete item.profitLossOrder
            let newItem = Object.assign(profitLossOrder, item)
            // 转换金额
            newItem.number = newItem.number ? formatNumber(newItem.number) : newItem.number
            newItem.zsNumber = newItem.zsNumber ? formatNumber(newItem.zsNumber) : newItem.zsNumber
            newItem.costPrice = newItem.costPrice ? formatPrice(newItem.costPrice) : newItem.costPrice
            newItem.price = newItem.price ? formatPrice(newItem.price) : newItem.price
            newItem.trimPrice = newItem.trimPrice ? formatMoney(newItem.trimPrice) : newItem.trimPrice
            newItem.commitTime = newItem.commitTime ? newItem.commitTime : ''
            newItem.checkTime = newItem.checkTime ? newItem.checkTime : ''
            newItem.createTime = newItem.createTime ? newItem.createTime : ''
            newItem.billTypeText = '报溢单'
            //0.待审核 5.审核通过 10.作废 15.反审 20.红冲 25.终止 30.完成
            if (newItem.billOrderStatus == '0') {
              newItem.billStatusText = "待审核"
            } else if (newItem.billOrderStatus == '5') {
              newItem.billStatusText = "已审核"
            } else if (newItem.billOrderStatus == '10') {
              newItem.billStatusText = "已作废"
            } else if (newItem.billOrderStatus == '15') {
              newItem.billStatusText = "已反审"
            } else if (newItem.billOrderStatus == '20') {
              newItem.billStatusText = "已红冲"
            }
            this.tableData.push(newItem)
          })
          this.total = res.result.total
        }
      })
    },
    // 判断当前选择时间段
    changeDate(val) {
      this.isShowDate = true
      switch (val) {
        case '全部':
          this.isShowDate = false
          this.queryData.startDate = ''
          this.queryData.finishDate = ''
          break
        case '今日':
          this.getTimeRange(this.$setTimeRange(1))
          break
        case '昨天':
          this.getTimeRange(this.$setTimeRange(2))
          break
        case '本周':
          this.getTimeRange(this.$setTimeRange(3))
          break
        case '上周':
          this.getTimeRange(this.$setTimeRange(4))
          break
        case '本月':
          this.getTimeRange(this.$setTimeRange(5))
          break
        case '上月':
          this.getTimeRange(this.$setTimeRange(6))
          break
        case '本年':
          this.getTimeRange(this.$setTimeRange(7))
          break
        case '去年':
          this.getTimeRange(this.$setTimeRange(8))
          break
        default:
          break
      }
    },
    // 获取时间范围并设置
    getTimeRange(data) {
      this.nowDate = [data.now, data.end]
      this.queryData.startDate = data.now + ' 00:00:00'
      this.queryData.finishDate = data.end + ' 23:59:59'
    },
    // 获取当前选中时间
    onClickPicker(val) {
      this.queryData.startDate = val[0] + ' 00:00:00'
      this.queryData.finishDate = val[1] + ' 23:59:59'
    },
    // 触发列配置弹框
    onShowColumn() {
      this.$refs.setColumnRef.dialogVisible = true
    },
    // 合计列计算
    getSummaries(param) {
      const { columns, data } = param
      const sums = []
      columns.forEach((column, index) => {
        if (index === 0) {
          sums[index] = '合计'
        } else if (index === 1) {
          sums[index] = '共' + this.total + '条明细'
        } else if (column.property === 'number' || column.property === 'price'
          || column.property === 'zsNumber') {
          const values = data.map((item) => delcommafy(item[column.property]))
          if (!values.every((value) => isNaN(value))) {
            sums[index] = values.reduce((prev, curr) => {
              const value = delcommafy(curr)
              if (!isNaN(value)) {
                return prev + curr
              } else {
                return prev
              }
            }, 0)
            if (column.property === 'number' || column.property === 'zsNumber') {
              sums[index] = formatNumber(sums[index]) // 保留2位小数，解决小数列合计精度缺失的问题
            } else {
              sums[index] = formatMoney(sums[index]) // 保留2位小数，解决小数列合计精度缺失的问题
            }
          }
        } else {
          sums[index] = ''
        }
      })
      return sums
    },
    // 获取每页几条数据
    handleSizeChange(val) {
      this.queryData.pageSize = val
      this.getData()
    },
    // 获取当前第几页
    handleCurrentChange(val) {
      this.queryData.pageNo = val
      this.getData()
    },
    // 选中表格事件
    handleCurrentRow(val) {
      this.currentRow = val;
    },
    // 查看单据
    onLookBill() {
      let billId
      // 有选择跳转对应明细，没有默认最后一个
      if (this.currentRow) {
        billId = this.currentRow.billId
      } else {
        if (this.tableData && this.tableData.length > 0) {
          const length = this.tableData.length
          billId = this.tableData[length - 1].billId
        } else {
          return
        }
      }
      this.goByBill(billId)
    },
    // 跳转单据页面
    handleBill(val) {
      this.goByBill(val.billId)
    },
    // 跳转对应单据页面
    goByBill(billId) {
      this.$router.push({
        name: 'stockManage-stockBill-billOverflowOrder',
        params: {
          billId
        },
      })
    }
  },
}
</script>

<style lang="scss" scoped>
$font-size: 12px;
$height-input: 30px; //0.55rem的高度
$height: 50px; //1rem的高度

.basic_info {
  width: 100%;
  height: calc(100vh - 1.875117rem);
  background: #f0f2f5;
  box-sizing: border-box;
  padding: 0 0.168761rem 0.168761rem;
  display: flex;
  flex-direction: column;
}

.info_operation_btn {
  width: 100%;
  height: $height-input;
  display: flex;
  align-items: center;

  ::v-deep .el-button {
    width: 80px;
    height: $height-input;
    text-align: center;
    box-sizing: border-box;
    display: flex;
    align-items: center;
    justify-content: center;
    font-size: $font-size;
    border-radius: 0.1rem;
    border: none;
    margin-right: 6px;
    margin-left: 0;
  }

  .el-button--default {
    color: #666;
  }

  ::v-deep .el-select {
    width: 1rem;
    height: $height-input;
    box-sizing: border-box;
    margin-right: 0.112507rem;

    .el-input {
      .el-input__inner {
        height: $height-input;
        border: none;
        font-size: $font-size;
      }

      .el-input__suffix {
        height: $height-input;
        display: flex;
        align-items: center;
      }
    }
  }

  .btn_left {
    width: 60%;
    display: flex;
    justify-content: flex-start;
    align-items: center;

    p {
      font-size: $font-size;
      color: #666;
      margin: 0 0.1rem 0 0.187512rem;
    }

    .disabled_button {
      background: #cbced3 !important;
      color: #666 !important;
    }
  }

  .btn_right {
    width: 40%;
    display: flex;
    justify-content: flex-end;
    align-items: center;

    .set_up {
      font-size: 20px;
      color: rgb(153, 153, 153);
      margin-right: 12px;
    }
  }
}

.info_content_div {
  width: 100%;
  height: calc(100% - 1rem);
  background: #fff;
  box-sizing: border-box;
  padding: 0 0.168761rem;
  margin-top: 9px;
  display: flex;

  .div_table {
    width: 100%;
    height: 100%;
    display: flex;
    flex-direction: column;

    // justify-content: space-between;
    .div_screen {
      width: 100%;
      height: $height-input;
      display: flex;
      justify-content: space-between;
      margin-top: 15px;

      ::v-deep .el-select {
        width: 2.250141rem;
        height: $height-input;
        box-sizing: border-box;
        border-radius: 4px;

        .el-input {
          .el-input__inner {
            height: $height-input;
            border-color: #e3e3e3;
            font-size: $font-size;
            padding-left: 0.15rem;
          }

          .el-input__suffix {
            height: $height-input;
            display: flex;
            align-items: center;
          }
        }
      }

      .screen_left {
        width: calc(100% - 6.56291rem);
        height: 100%;
        box-sizing: border-box;
        display: flex;
        justify-content: flex-start;
        box-sizing: border-box;

        >p {
          height: $height-input;
          display: flex;
          align-items: center;
          font-size: $font-size;
          font-family: PingFang SC;
          font-weight: 400;
          line-height: 17px;
          margin-left: 35px;
          color: #1993FB;
          opacity: 1;
        }

        ::v-deep .el-button {
          width: 1rem;
          height: $height-input;
          display: flex;
          align-items: center;
          justify-content: center;
          font-size: $font-size;
          border-radius: 0.1rem;
          border: none;
        }

        ::v-deep .el-select {
          width: 80px;
          margin-right: 6px;
        }

        .date_picker_style {
          width: 3.375211rem;
          height: $height-input;
          background: #ffffff;
          border: 1px solid #d9d9d9;
          opacity: 1;
          border-radius: 0.075rem;
          position: relative;
          display: flex;
          align-items: center;
          justify-content: space-between;
          box-sizing: border-box;
          padding: 0.1rem;
          margin-right: 0.112507rem;
          position: relative;

          p {
            width: 100%;
            height: $height-input;
            margin: 0;
            font-size: $font-size;
            color: #666;
            font-family: HelveticaNeue;
            color: #666666;
            line-height: $height-input;
          }

          i {
            font-size: $font-size;
            color: #d9d9d9;
          }

          ::v-deep .el-date-editor {
            width: 178px;
            height: $height-input;
            opacity: 0;
            position: absolute;
            top: 0;
            left: 0;
            z-index: 2001;

            .el-range-input {
              font-size: $font-size;
            }

            .el-range-separator {
              line-height: $height-input;
              font-size: $font-size;
            }
          }
        }

        ::v-deep .el-date-editor {
          width: 178px;
          height: $height-input;
          background: #ffffff;
          border: 1px solid #d9d9d9;
          margin-right: 0.112507rem;
          padding: 3px 6px;

          .el-range__icon {
            position: absolute;
            right: 0;
            line-height: 30px;
          }

          .el-range-separator {
            line-height: 24px;
          }

          .el-range-input {
            font-size: $font-size;
          }

          .el-range__close-icon {
            display: none;
          }
        }
      }

      .screen_right {
        width: 6.56291rem;
        height: $height-input;
        box-sizing: border-box;
        display: flex;
        justify-content: flex-end;
        align-items: flex-start;
        flex-wrap: wrap;

        ::v-deep .el-checkbox {
          display: flex;
          align-items: center;
          margin-left: 0.168761rem;

          .el-checkbox__input {
            height: 14px;
          }

          .el-checkbox__label {
            font-size: $font-size;
            padding-left: 0.1rem;
            color: #666;
          }

          .is-checked {
            .el-checkbox__inner {
              background: #1a93fa;
              border-color: #1a93fa;
            }
          }
        }

        >p {
          height: $height-input;
          display: flex;
          align-items: center;
          font-size: $font-size;
          font-family: PingFang SC;
          font-weight: 400;
          line-height: 17px;
          color: #666666;
          opacity: 1;

          &:nth-child(2) {
            color: #1993fb;
          }

          &:nth-child(3) {
            color: #fd6c21;
          }
        }
      }
    }

    .table_content {
      height: calc(100% - 70px - 60px - 10px);
      margin-top: 15px;

      ::v-deep .el-table {
        border: 1px solid #e3e3e3;
        border-bottom: none;
        box-sizing: border-box;

        th,
        td {
          padding: 0;
          color: #666;
          box-sizing: border-box;
          border-right: 1px solid #e3e3e3;

          .cell {
            height: 50px;
            display: flex;
            align-items: center;
            font-size: $font-size;
          }

          &:first-child {
            .cell {
              justify-content: center;
              padding: 0;
            }
          }
        }

        th {
          .cell {
            display: block;
            height: 30px;
            line-height: 30px;
            background: #ededed;
            justify-content: center;
          }
        }

        .el-table__body tr:hover>td {
          background: #e3f6ff;
        }

        .el-table__footer-wrapper {
          td {
            background: #f4f4f4;
            border: none;
          }
        }

        //滚动条的宽度
        ::-webkit-scrollbar {
          width: 8px;
          height: 10px;
          background-color: #e5e5e5;
        }

        //滚动条的滑块
        ::-webkit-scrollbar-thumb {
          background-color: #c9c9c9;
        }
      }
    }

    .table_pagination {
      width: 100%;
      height: 1rem;
      box-sizing: border-box;
      padding: 0.168761rem 0;
      display: flex;

      .pagination_div {
        width: 100%;
        display: flex;
        align-items: center;
        justify-content: flex-end;

        ::v-deep .el-pagination {
          padding: 0;
          height: 0.525033rem;

          .el-pagination__sizes {
            margin: 0;

            .el-input {
              margin-right: 0;
            }
          }
        }
      }
    }
  }
}
</style>